normal probability density function

(1 / sqrt(2*pi*3^2)) * exp(((-(75-69)^2)/(2*3^2)))

Figuring out rnorm()

rnorm(7, mean = c(10, 100, 1000), sd = c(0, 1, 10))

tibble(
  n = 2,
  mean = c(10, 100, 1000), 
  sd = c(0, 0, 0)
) %>% 
  mutate(sample = list(rnorm(n, mean, sd))) %>% 
  unnest()

# this is for another time. But how does rnorm wiork within a dataframe? 

rnorm() will use the vector pairs sequentially and then restart from 1.



joepowers16/rethinking documentation built on June 2, 2019, 6:52 p.m.